// 角色管理数据ts类型
import type { ResponseData } from '@/api/public'
import type { AllRoles } from '../user/type'

// 获取角色列表接口的返回值
export interface ResRoleList extends ResponseData {
  data: {
    records: AllRoles
    total: number
  }
}


// 菜单权限数据类型（嵌套类型）
export interface MenuData{
  id: number,
  createTime: string,
  updateTime: string,
  pid: number,
  name: string,
  code: string,
  toCode: string,
  type: number,
  status: number,
  level: number,   //菜单层级
  children?: MenuList,  // 子菜单列表
  select: boolean
}
export type MenuList = MenuData[]

// 获取菜单权限接口返回值类型
export interface ResMenuList extends ResponseData{
  data: MenuList
}